<%@ page language="java" pageEncoding="UTF-8" %>
<%@ taglib prefix="s" uri="/struts-tags" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
    <title>展示鲜花</title>
    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    <meta http-equiv="description" content="This is my page">
    <link rel="stylesheet" type="text/css" href="assets/css/flower.css">
</head>

<body>
<div class="content">
    <div class="left">
    </div>
    <div class="right">
        <div style="padding-left:200px;width: 600px;">
            <s:action name="browseCatalog" executeResult="false"/>
            <s:set value="#request.flower" id="flower"/>
            <s:form action="addOrUpdateFlower" method="post" enctype="multipart/form-data">
            <tr>
                <td></td>
                <td>请在此修改花品的信息</td>
            </tr>
            <s:textfield label="品名" name="flower.flowername" value="%{#flower.flowername}"/>
            <tr>
                <td>
                    价格
                </td>
                <td>
                    <input type="text" name="flower.price" value="<s:property value="#flower.price"/>"> <label>元</label>
                </td>
            </tr>
            <s:set value="#request.catalogs" id="catalog"/>
            <s:select label="分类" list="#catalog" listKey="catalogid" listValue="catalogname"
                      name="flower.catalog.catalogid" value="%{#flower.catalog.catalogid}"/>
            <tr>
                <td>

                </td>
                <td>
                    <input type="file" name="upload" value="<s:property value="#flower.picture"/>"/>
                </td>
                <td>
                    <img alt="" src="assets/pic/<s:property value="#flower.picture"/>">
                </td>
            </tr>
            <s:hidden name="flower.flowerid" value="%{#flower.flowerid}"/>
            <s:hidden name="picture" value="%{#flower.picture}"></
        </s:hidden>>
        <s:submit value="修改"/>
        </s:form>
    </div>
</div>
</div>
<jsp:include page="foot.jsp"/>
</body>
</html>
